home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group93b.txt / 000064_icon-group-sender _Fri May 7 09:44:23 1993.msg < prev    next >
Internet Message Format  |  1993-06-16  |  2KB

  1. Received: by cheltenham.cs.arizona.edu; Fri, 7 May 1993 11:40:17 MST
  2. Date: 07 May 1993 09:44:23 -0600 (CST)
  3. From: Chris Tenaglia - 257-8765 <TENAGLIA@mis.mcw.edu>
  4. Subject: Handy Icon Utility
  5. To: icon-group@cs.arizona.edu
  6. Message-Id: <01GXW15C1RDS8WW2LB@mis.mcw.edu>
  7. Organization: Medical College of Wisconsin (Milwaukee, WI)
  8. X-Vms-To: in%"icon-group@cs.arizona.edu"
  9. Mime-Version: 1.0
  10. Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
  11. Content-Transfer-Encoding: 7BIT
  12. Status: R
  13. Errors-To: icon-group-errors@cs.arizona.edu
  14.  
  15.  
  16. Anyone interested in some small useful iconware? Here's one we use here a lot.
  17. It's called slave, for slave printer. It allows users to print files to slave
  18. printers directly attached to PCs, MACs, and Terminals running VT/Ansi screen
  19. modes. It works as both a utility and filter.
  20.  
  21.           Usage : slave file
  22.                   slave <file
  23.                   who|slave
  24.  
  25. I use it for printing email messages from PINE or ELM to the slave printer
  26. attached to my terminal. No lpd or vms queue services needed. I've used it
  27. under Ultrix and VMS.
  28.  
  29. Chris Tenaglia (System Manager) | Medical College of Wisconsin
  30. 8701 W. Watertown Plank Rd.     | Milwaukee, WI 53226
  31. (414)257-8765                   | tenaglia@mis.mcw.edu, mcwmis!tenaglia
  32.  
  33.  
  34.  
  35. #
  36. # FILE : SLAVE.ICN
  37. # DESC : LISTS TO AN ATTACHED SLAVE PRINTER EITHER FILE OR PIPE
  38. #        IT EVEN DOES A FORM FEED WHEN FINISHED
  39. #
  40. # UPDATE          BY            WHAT
  41. # 08-APR-1992     TENAGLIA      INITIAL CREATION
  42. #
  43. procedure main(param)
  44.   if match("-h",param[1]) then help()
  45.   args := ""
  46.   in := open(param[1])
  47.   write("\e[5i")  # turn on slave printer
  48.   if match("-h",param[1]) then help()
  49.                           else while write(read(in))
  50.   write("\f")     # eject at end of document
  51.   write("\e[4i")  # turn off slave printer
  52.   if type(in)=="file" then close(in)
  53.   end
  54.  
  55. #
  56. # built in help goes both the screen and slave printer
  57. #
  58. procedure help()
  59.   write(&errout,"slave -- output to attached slave printer")
  60.   write(&errout,"         usage : slave FILENAME")
  61.   write(&errout,"                 slave <FILENAME")
  62.   write(&errout,"                 ls -al | slave")
  63.   stop(" ")
  64.   end
  65.  
  66.